﻿@model IEnumerable<KinoDB.Models.Kinosaal>

@{
    ViewBag.Title = "RoomManagement";
}

<h2>Kinosäle</h2>

<p>
    @Html.ActionLink("Create New", "CreateRoom")
</p>
<table class="table">
    <tr>
        <th>
            @Html.DisplayNameFor(model => model.Name)
        </th>
        <th>
            @Html.DisplayNameFor(model => model.Sitzplatzzahl)
        </th>
        <th></th>
    </tr>

@foreach (var item in Model) {
    <tr>
        <td>
            @Html.DisplayFor(modelItem => item.Name)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.Sitzplatzzahl)
        </td>
        <td>
            @Html.ActionLink("Edit", "EditRoom", new { id=item.Id }) |
            @Html.ActionLink("Delete", "DeleteRoom", new { id=item.Id })
        </td>
    </tr>
}

</table>
